package com.chinapost.action;

import org.apache.struts2.convention.annotation.Action;
import org.apache.struts2.convention.annotation.Namespace;
import org.apache.struts2.convention.annotation.Result;
import org.springframework.beans.factory.annotation.Autowired;

import com.chinapost.service.DqlktServiceI;
import com.chinapost.vo.Dqlkt;
import com.opensymphony.xwork2.ModelDriven;

@Namespace("/")
@Action(value = "dqlktAction", results = { @Result(name = "dqlktManager", location = "/jsp/dqlkt/dqlktManager.jsp") 
	 })
public class DqlktdAction extends BaseAction implements ModelDriven<Dqlkt> {

	private DqlktServiceI dqlktService;
	private Dqlkt dqlkt = new Dqlkt();


	public DqlktServiceI getDqlktService() {
		return dqlktService;
	}

	@Autowired
	public void setDqlktService(DqlktServiceI dqlktService) {
		this.dqlktService = dqlktService;
	}

	@Override
	public Dqlkt getModel() {
		return dqlkt;
	}

	public String dqlktManager() {
		return "dqlktManager";
	}


	public void datagrid() {
		super.writeJsonDate(dqlktService.datagrid(dqlkt));
	}

}
